package cn.runnable;

/**
 * @author Mxb
 * @version 1.0
 * @date 2020/7/26 16:16
 */
public class Main {
    public static void main(String[] args) {
        Runnable r = new RunnableDemo();
        Runnable r2 = new RunnableDemo2();
        Thread t2 = new Thread(r2);
        t2.setName("线程2");
        Thread t = new Thread(r);
        t.setName("线程1");

        t2.start();
        t.start();
    }
}
